﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="UInvoiceReceiving.ascx.cs"
    Inherits="PayRoller.Include.UInvoiceReceiving" %>
<%@ Register Assembly="Huayou.Common" Namespace="Huayou.UI.WebControls" TagPrefix="cc1" %>
<script type="text/javascript">
    function confirmReceipt() {
        return confirm("Do you confirm the  receipt?");
    }
</script>
<table width="99%" border="0" cellspacing="0" cellpadding="0" align="center" class="NormalText">
    <tr>
        <td style="height: 40px" class="HeadText">
            Receiving Payments
        </td>
    </tr>
    <tr>
        <td>
            <table width="100%" border="0" cellspacing="1" cellpadding="1" id="TABLE1" onclick="return TABLE1_onclick()">
                <tr>
                    <td width="12%" height="22">
                        Client ID:
                    </td>
                    <td>
                        <asp:Label ID="labClientID" runat="server"></asp:Label>
                    </td>
                    <td width="15%">
                        Remain Balance:
                    </td>
                    <td>
                        <asp:Label ID="labRemainBalance" runat="server"></asp:Label>
                    </td>
                </tr>
                <tr>
                    <td width="12%" height="22">
                        Client Name:
                    </td>
                    <td>
                        <asp:Label ID="labClientName" runat="server"></asp:Label>
                    </td>
                    <td width="15%">
                        Received Amount:
                    </td>
                    <td>
                        <asp:TextBox ID="txtReceived" runat="server"></asp:TextBox>
                        &nbsp;<asp:Button ID="btnSearch" runat="server" Text="Receive" CssClass="submitBtn"
                            OnClick="btnReceive_Click" OnClientClick="return confirmReceipt();" />
                        <asp:Label ID="labCurrentBalance" runat="server" Visible="false" Text="0"></asp:Label><asp:Label
                            ID="labClosingBalance" runat="server" Text="0" Visible="false"></asp:Label>
                    </td>
                </tr>
            </table>
        </td>
    </tr>
    <tr>
        <td height="22">
            <cc1:DataGridTable CellPadding="1" CellSpacing="1" BackColor="#CCCCCC" Width="100%"
                ID="dgdList" runat="server" BorderWidth="0px" BorderStyle="None" IsAllowPaging="True"
                PageSize="12" OnDataBinding="dgdList_DataBinding" OnPageIndexChanged="dgdList_PageIndexChanged"
                AutoGenerateColumns="False" CssClass="tableGrid" MaxRecord="0" PageCSS="scrollButton"
                AllowPaging="True" OnItemDataBound="dgdList_ItemDataBound" OnCancelCommand="dgdList_CancelCommand"
                OnEditCommand="dgdList_EditCommand" OnUpdateCommand="dgdList_UpdateCommand" DataKeyField="Sid">
                <PagerStyle CssClass="gridPager" BackColor="White" />
                <SelectedItemStyle CssClass="gridSelectedItem" />
                <ItemStyle Height="25px" CssClass="gridItem" BackColor="White"></ItemStyle>
                <HeaderStyle Height="22px" CssClass="right-ta-ti01" Font-Bold="True"></HeaderStyle>
                <AlternatingItemStyle CssClass="gridAltItem" />
                <FooterStyle CssClass="gridFooter" BackColor="White" />
                <EditItemStyle CssClass="gridEditItem" />
                <Columns>
                    <asp:BoundColumn DataField="Sid" HeaderText="Invoice No" ReadOnly="True"></asp:BoundColumn>
                    <asp:BoundColumn DataField="InvoiceDate" HeaderText="Date Of Invoice" ReadOnly="True"
                        DataFormatString="{0:dd/MM/yyyy}"></asp:BoundColumn>
                    <asp:BoundColumn DataField="InvoiceAmount" HeaderText="Amount of Invoice" ReadOnly="True">
                    </asp:BoundColumn>
                    <asp:BoundColumn DataField="OtherFee" HeaderText="OtherFee of Invoice" ReadOnly="True">
                    </asp:BoundColumn>
                    <asp:BoundColumn DataField="ReceiveAmount" HeaderText="Receipt Amount"></asp:BoundColumn>
                    <asp:TemplateColumn HeaderText="Status">
                        <ItemTemplate>
                            <asp:Label ID="labStatus" runat="server"></asp:Label>
                        </ItemTemplate>
                    </asp:TemplateColumn>
                    <asp:TemplateColumn HeaderText="Detail">
                        <ItemTemplate>
                            <a href="../Invoices/InvoiceDetail.aspx?Guid=<%# Eval("Guid")%>&OrgSid=<%# Eval("OrgSid")%>"
                                target="_blank">Detail</a>
                        </ItemTemplate>
                    </asp:TemplateColumn>
                </Columns>
            </cc1:DataGridTable>
        </td>
    </tr>
    <tr>
        <td align="left">
            <asp:TextBox ID="txtParamstr" runat="server" Visible="False" Width="48px"></asp:TextBox>
        </td>
    </tr>
    <tr>
        <td align="center">
            <asp:Label ID="lblTip" runat="server"></asp:Label>
            &nbsp;&nbsp; <a runat="server" id="hrefReturn" href="Receipt.aspx">Return</a>
        </td>
    </tr>
</table>
